<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core">

<ui:composition template="./masterpage/masterpage.xhtml">
	<ui:define name="title">Change password</ui:define>
	<ui:define name="content">
		<h:form>


			<div class="title">Change your password</div>

			<table width="500">
				<tbody>
					<tr>
						<td colspan="2"><h:messages style="color: red;"></h:messages>
						</td>
					</tr>
					<tr>
						<td>Old password:</td>
						<td><h:inputSecret id="txtOldPass" label="Old password"
								styleClass="input" required="true"
								value="#{internetProfileManageBean.oldPassword}">
								<f:validateLength minimum="6"></f:validateLength>
							</h:inputSecret></td>
					</tr>
					<tr>
						<td>New password:</td>
						<td><h:inputSecret id="txtNewPass" label="New Password"
								styleClass="input" required="true"
								value="#{internetProfileManageBean.newPassword}">
								<f:validator validatorId="passwordValidator"></f:validator>
								<f:attribute name="txtConfirm" value="#{confirm}"></f:attribute>
								<f:validateLength minimum="6"></f:validateLength>
							</h:inputSecret></td>
					</tr>
					<tr>
						<td>Confirm password:</td>
						<td><h:inputSecret id="txtConfirm" label="Confirm password"
								styleClass="input" required="true" binding="#{confirm}">
								<f:validateLength minimum="6"></f:validateLength>
							</h:inputSecret></td>
					</tr>
					<tr>
						<td colspan="2" style="text-align: right;"><h:commandButton
								id="btnSubmit" value="Change" styleClass="btnSubmit"
								action="#{internetProfileManageBean.changePass}"></h:commandButton>
						</td>
					</tr>
				</tbody>
			</table>

		</h:form>
	</ui:define>
</ui:composition>
</html>